package com.zly.framework.rbac.model.entity;

import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.v3.oas.annotations.media.Schema;
import io.swagger.v3.oas.annotations.tags.Tag;
import jakarta.persistence.Column;
import jakarta.persistence.Entity;
import jakarta.persistence.Table;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.ToString;

import java.io.Serial;

/**
 * @author 钟刘扬
 */

@Data
@EqualsAndHashCode(callSuper = true)
@Entity
@Table(name = "sys_role_permission")
@TableName("sys_role_permission")
@Tag(name = "角色权限")
@ToString(callSuper = true)
public class RolePermission extends BaseEntity {

    @Serial
    private static final long serialVersionUID = 1L;

    @Schema(description = "权限ID")
    @Column(name = "permission_id")
    private Long permissionId;

    @Schema(description = "角色ID")
    @Column(name = "role_id")
    private Long roleId;
}